package ningbo.inter;

/**
 * @Author 宁铂
 * @Date 2021/7/14 16:53
 * @Version 1.0
 */
public class TestInter {
    public static void main(String[] args) {
        /** 和重象类一样，接口也不能创建对象 */
        Inter inter = new InterImpl();
        inter.eat();
        inter.play();

        /** 创建实现类对象进行测试 -- 常用 */
        InterImpl inter1 = new InterImpl();
        inter1.eat();
        inter1.play();

    }
}
